package com.xiweicheng.test.delay_task;

import java.util.concurrent.TimeUnit;

public class DelayTaskMain {
    public static void main(String[] args) {
        DelayTask taskOne = new DelayTask("任务一");
        DelayTask taskTwo = new DelayTask("任务二");
        DelayTask taskThree = new DelayTask("任务三");
        DelayQueueCostomizedManager manager = DelayQueueCostomizedManager.getInstance();
        manager.put(taskOne, 5L, TimeUnit.SECONDS);
        manager.put(taskTwo, 1L, TimeUnit.SECONDS);
        manager.put(taskThree, 2L, TimeUnit.SECONDS);
    }
}
